<%@page import="rjeutsky.models.User"%>
<%@page import="java.util.List"%>
<%@page import="rjeutsky.ControllerWrapper"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="mytags" uri="/WEB-INF/tld/mytags.tld"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Пользователи</title>
</head>
<mytags:AuthenticationLevel userLevelString="ADMIN"/>
<%
	List<User> users = ControllerWrapper.getApplicationController()
			.getUsers();
	pageContext.setAttribute("items", users);
%>
<body>
	<table>
		<tr>
			<td><jsp:include page="Menu.jsp" /></td>
			<td><span class="info">${param.infoText}</span>
				<table>
					<tr>
						<th>Имя пользователя</th>
						<th></th>
					</tr>
					<c:forEach var="user" items="${items }">
						<tr>
							<td>${user.login}</td>
							<td><a
								href="${pageContext.request.contextPath}/UserPublications.jsp?id=${user.id}">Выписанные
									издания</a></td>
						</tr>
					</c:forEach>
				</table> </td>
		</tr>
	</table>
</body>
</html>